import { http } from "@/utils";
import { makeAutoObservable } from "mobx";
class ChannelStore {
  channels = [];
  constructor() {
    makeAutoObservable(this);
  }
  async getChannel() {
    const res = await http.get("/channels");
    this.setChannels(res.data.channels);
  }
  setChannels(data) {
    this.channels = data;
  }
}
export default ChannelStore;
